/**
 * 分类
 * 路由
 */
const express = require("express");
const router = express.Router();
const validateRequest = require("../middlewares/validationMiddleware"); // 验证器
// 检验器
const { list_validation, add_validation, update_validation, delete_validation } = require("../validators/category");
const { category_list, category_add, category_update, category_delete } = require("../controllers/category");

router.get("/categoryList", list_validation, validateRequest, category_list); // 获取视频中心
router.post("/categoryAdd", add_validation, validateRequest, category_add); // 编辑视频中心
router.put("/categoryUpdate", update_validation, validateRequest, category_update); // 编辑视频中心
router.delete("/categoryDetele", delete_validation, validateRequest, category_delete); // 删除视频中心

module.exports = router;
